#ifndef _TEST6222011_H_
#define _TEST6222011_H_

#include <cstring>

class TestCase;
// final class, not derivable
class TestSuite
{
private:
	TestSuite();

	TestCase* first, *last;
public:
	static TestSuite& getInstance();

	void addCase(TestCase* _case);

	void doTest();

	void init();

	void destory();
};

class TestCase
{
	friend TestSuite;
public:
	TestCase()
	{
		next = NULL;
	}

	virtual ~TestCase(){};

	virtual void init() {};

	virtual void destory() {};

	virtual void proc() {};

private:
	TestCase* next;
};

#endif //_TEST6222011_H_
